// Copyright 2022 jeff.li. and/or its affiliates.

#pragma once

#include <type_traits>

namespace tbir::runtime {
    namespace {

        template<class...>
        using __my_void_t_for_hash__ = void;

        template<typename T, typename = __my_void_t_for_hash__<>>
        struct is_std_hashable : std::false_type {
        };

        template<typename T>
        struct is_std_hashable<
                T,
                __my_void_t_for_hash__<decltype(std::declval<std::hash<T>>()(std::declval<T>()), void())>>
                : std::true_type {
        };

    }  // namespace
}  // namespace tbir::runtime
